Description
Golazo-style team statistics in the game detail: possession as a split gradient bar, shots / shots-on-target / corners / fouls as mirrored comparison bars. Data is already available but unused: ESPN soccer summary boxscore.teams[].statistics (possessionPct, totalShots, shotsOnTarget, wonCorners, foulsCommitted, saves, passes). Extend model.GameDetail + espn mapping to capture team-level stats; render bars with block shading (โโโ). Also applies to MLB/NBA/NHL/NFL team statistics.
Acceptance Criteria
- #1 soccer detail shows possession + shots bars from boxscore.teams stats
- #2 bars use block shading and team colors
Final Summary
Added soccer team-stat comparison bars to the game detail view.
What:
- model.GameDetail gains TeamStats []model.TeamStat (Label/Key/Away/Home).
- espn: summary boxscore now decodes the flat team stat list (boxscore.teams[].statistics). mapTeamStats pairs home vs away for a curated, ordered subset (possession, shots, on-target, corners, fouls, saves); returns nil unless both sides present (stick-and-ball sports nest team stats differently and are left to the existing per-player box score).
- UI: teamStatsBlock renders each stat as a proportional split bar (away|home) in team colors with block shading (โ / โ fallback when 0-0), value on each side, label centered above. Shown above the soccer Key Events timeline.
Tests: mapTeamStats (curated/ordered pairing + present-keys-only) and both-sides-required guard; live-smoke verified 6 stats map for a real World Cup game. go vet + go test ./... pass.